home *** CD-ROM | disk | FTP | other *** search
/ Chip: 2005 Utilities / CHIP Utilities 2005 / CHIP Utilities 2005.iso / dosapps / lfntools / readme.txt < prev   
Encoding:
Text File  |  2002-09-03  |  19.8 KB  |  455 lines

  1. Odi's DOS tools for long file names
  2. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  3. ALWAYS GET THE LATEST VERSION FROM http://www.odi.ch/
  4. AND READ THIS BEFORE SENDING ME EMAIL!
  5.  
  6. Contents
  7. --------
  8.  
  9. 1. Overview
  10. 2. Description
  11. 3. Known bugs 
  12. 4. Where can I report bugs and get the latest version?
  13. 5. FAQ
  14. 6. License
  15. 7. Acknowledgements
  16.  
  17. 1. Overview
  18. 1.1 What's this?
  19. ----------------
  20. These tools provide easy file management under DOS with long filenames created by 
  21. Windows 95/98 on FAT32, FAT16 and FAT12 file systems. To take full advantage of these 
  22. tools, run them in pure DOS mode - not a DOS box under Windows. As far as I know this 
  23. is the only completely FREE solution to handle long filenames in DOS.
  24.  
  25. To show you what I mean: Open up a DOS box in Windows 95 and type DIR - it will 
  26. display long filenames. Do the same in DOS mode and you will only get the short 
  27. names. Copy a file with a long filename in DOS mode and it will lose its long name.
  28. Using my LFN Tools you can just feel like in a DOS box when you are actually in DOS 
  29. mode. Typing LDIR brings up the directory with its long filenames. Copying a file 
  30. with LCOPY preserves long filenames. You can even create directories (LMD) with long 
  31. names or rename files (LREN) with long names.
  32.  
  33. 1.2 What is it not?
  34. -------------------
  35. It is NOT an extension of DOS. All your DOS programs can NOT handle long file names 
  36. even with these tools. (I should mention that there is a driver called LFNDOS that 
  37. provides the Microsoft Long Filename API under DOS. You can find it somewhere on the 
  38. web.) Other file systems than FAT and ISO-9660/Joliet for CD-ROMs are not supported 
  39. yet. Thus these tools do not work on Apple Mac-Drives, Windows NT-Drives, Linux etc. 
  40. But they run on Iomega ZIP drives. They are not supposed to run in a DOS-Box under 
  41. Windows nor are they supposed to handle any short names. Use the generic DOS commands 
  42. instead.
  43. Do not use with Windows NT or Windows 2000.
  44.  
  45. 1.3 Who may need these tools?
  46. -----------------------------
  47. Anyone who has Windows 9x/me running. Anyone who wants to make a backup copy of his 
  48. Windows. Anyone who loves good old DOS. Anyone who must work in DOS mode for 
  49. maintainance of the OS. Are you reinstalling Windows cause it's wrecked and want to 
  50. backup all your data? Bought a new Harddrive and do not want to reinstall Windows? 
  51. LCopy it! Want to restore your Windows directory from a ZIP drive or CD-ROM? Try it!
  52.  
  53. 1.4 What do the tools do?
  54. -------------------------
  55. Each tool corresponds to a DOS equivalent but can handle long file names and FAT32.
  56.  
  57. LDIR.EXE   List a directory/folder like DIR
  58. LCD.EXE    Changes to any directory/folder like CD
  59. LREN.EXE   Renames a file like REN
  60. LDEL.EXE   Deletes a file line DEL
  61. LCHK.EXE   Display information about a volume
  62. LCOPY.EXE  Copies files better than COPY
  63. LMD.EXE    Creates a directory like MD
  64. LRD.EXE    Removes a directory like RD
  65.  
  66. 1.5 How do the tools work internally?
  67. -------------------------------------
  68. They do not use the common DOS calls to handle files and/or directories. Instead they 
  69. access disks directly either through BIOS INT 25h and 26h or Int 21h function 7305h, 
  70. depending on the version of operating system. For CD-ROM access Int 2Fh function 15h 
  71. is used. Thus only FAT file systems and ISO9660/Joliet are supported. Five different 
  72. file systems after all.
  73.  
  74. 1.6 What's new?
  75. ---------------
  76. To find out what version you have run LCHK. For details see history.txt.
  77.  
  78. 1.7 A note on CD-ROM file systems
  79. ---------------------------------
  80. On Windows platforms mostly two file systems (FS) are used for CD-ROMs at the same 
  81. time: ISO-9660 and Microsoft Joliet (which is optional). Windows uses Joliet if 
  82. available. DOS always uses ISO. ISO can either store short names in uppercase OR long 
  83. names (31 characters) in a reduced ASCII character set. Long names are converted to 
  84. short ones in DOS. Joliet can use long filenames in Unicode characters. This is the 
  85. reason for the /I switch. 
  86.  
  87. 1.8 Multisession CD-ROMs
  88. ------------------------
  89. LFN Tools are capable of accessing previously recorded sessions on Multisession CD-
  90. Rs. LCHK can list all tracks on a CD. Every track containing DATA is considered a 
  91. "session" and has its own file system. Sessions can include or "overwrite" files from 
  92. previous session. A new session can "delete" a file by simply not making a directory 
  93. entry for it. With LFN Tools you are able to recover such "deleted" files.
  94.  
  95. 1.9 Extended memory EMS and XMS
  96. -------------------------------
  97. LCOPY by default tries to use extended memory for its disk cache (2'393'300 bytes). 
  98. This can improve performance on huge directories like the Windows\System directory. 
  99. However for the extended memory to be used you need to load a memory manager like 
  100. EMM386 in your config.sys. The simplest way to do so is to include the following line 
  101. in your config.sys file:
  102. device=c:\windows\emm386.exe RAM
  103. If no memory manager is installed LCOPY can not use extended memory and so uses its 
  104. standard cache method. Use the /V switch with LCOPY to turn off use of extended 
  105. memory.
  106. All the other tools do by default NOT use extended memory because overhead would be 
  107. too big and performance would not necessarily be better.
  108.  
  109. 2. Description
  110.  
  111. Note: When working with long filenames files do not need to have any extension or can 
  112. have more than one. For example: "Mailbox", "Mail from Mama.txt", "Book.doc.zip". 
  113. Thus wildcards do behave slightly different. (Microsoft's DOS Box instead keeps the 
  114. behaviour compatible to DOS.) To select all files use a single * instead of *.*. 
  115. Because *.* would select all files containing a dot - and most of the directory names 
  116. don't!
  117.  
  118. Switches need not be separated by spaces anymore. However when using /Tnn it must be 
  119. followed by a space if additional switches are specified. Otherwise they are ignored!
  120.  
  121. 2.1 LDIR
  122. --------
  123. This command displays the specified directory if supplied a long directory name. 
  124. Without parameters it displays the current directory. If the path or filename 
  125. contains spaces double quotes are required (see example). You can use the common 
  126. wildcards (?,*) to restrict the output to certain files. Use asterix to abreviate a 
  127. long directory name. The /a switch displays hidden files too. The /b switch displays 
  128. only long file names; no date/time information. The /s switch displays all 
  129. subdirectories. When viewing large directories use the /p switch to pause listing 
  130. between screen pages. Witch the /c switch you can turn off the cache. This will slow 
  131. down the whole thing a bit, but consumes less memory (~128 KB). The /I and /T 
  132. switches are for CD-ROM only. /I forces LDIR to use ISO file system rather than 
  133. Joliet. /T must be followed by the number of a valid data track and a space. The 
  134. track number identifies which session to use. When /T is absent the last session 
  135. recorded is used. Use LCHK to display valid track numbers.
  136.  
  137. Note: When using quotation marks never put a backslash at the end! (See "Known Bugs & 
  138. Features" for details)
  139.  
  140. Syntax:  LDIR [drive:][path][filename] [/?] [/A][/B][/S][/P]
  141.     [/C][/I][/Tn]
  142.  
  143. Example: D:\WINDOZE>LDIR "C:\new folder\*.txt"
  144.  
  145.          .       .    <DIR>       13.01.1999  19:49  .
  146.          ..      .    <DIR>       13.01.1999  19:49  ..
  147.          NEWTEX~1.TXT        1247 13.01.1999  20:02  New textfile.txt
  148.  
  149.          D:\>LDIR w*
  150.  
  151.          WINDOZE .    <DIR>       13.01.1999  19:49  Windoze
  152.  
  153.          D:\>LDIR w*\
  154.  
  155.          .       .    <DIR>       13.01.1999  19:49  .
  156.          ..      .    <DIR>       13.01.1999  19:49  ..
  157.          NEWTEX~1.TXT        1247 13.01.1999  20:02  New textfile.txt
  158.  
  159.  
  160. 2.2 LCD
  161. -------
  162. This command changes the current working directory to the specified location. Unlike 
  163. the corresponding DOS command LCD changes directly to a specified drive (see 
  164. example). LCD will change to the first matching directory it meets. In addition 
  165. wildcards can be used in pathnames. The first item occuring in the directory 
  166. structure (this could be a file!) is used. The /I and /T switches are for CD-ROM 
  167. only. /I forces LDIR to use ISO file system rather than Joliet. /T must be followed 
  168. by the number of a data track. The track number identifies which session to use. When 
  169. /T is absent the last session recorded is used. Use LCHK to display valid track 
  170. numbers.
  171.  
  172.  
  173. Syntax:  LCD [drive:]pathmask [/?][/I][/Tn]
  174.  
  175. Example: D:\WINDOZE>LCD "C:\new folder"
  176.  
  177.          C:\NEWFOL~1>LCD ..
  178.  
  179.          C:\>LCD pro*\onli*
  180.  
  181.          C:\PROGRA~1\ONLINE~1>
  182.  
  183. 2.3 LDEL
  184. --------
  185. This command deletes the specified file(s). You can use the common wildcards (?,*) to 
  186. select more than one file. The /s switch also deletes files found in subdirectories. 
  187. Empty subdirectories are deleted automatically. The /a switch also deletes files with 
  188. the read-only attribute set. If combined with the /s switch also read-only 
  189. directories are processed. Hidden, system etc. files / directories are NOT affected 
  190. by /a. To remove even those use /f. /f automatically includes /a. The /p switch asks 
  191. you before deleting each file wheter to proceed or not. With the /c switch you can 
  192. turn off the cache. This will slow down the whole thing a bit, but consumes less 
  193. memory (~128 KB). To delete all files in a directory use "LDEL *" istead of "LDEL 
  194. *.*".
  195.  
  196.  
  197. Syntax:  LDEL [drive:][path\]file [/A][/F][/S][/P][/C][/?]
  198.  
  199. Example: C:\TEMP>LDEL *.txt
  200.          Letter from Al.txt deleted
  201.          My memories.txt deleted
  202.  
  203.          C:\TEMP>LDEL "E:\Garbage folder\*"
  204.          Trash 1.dat deleted
  205.          Trash 2.file deleted
  206.  
  207. Use /s with extreme care!
  208. LDEL D:\* /s /f          Deletes everything on drive D:
  209. LDEL d:\temp /s          Removes all files called temp from all directories on D:
  210. LDEL d:\temp\* /s        Removes all files from directory D:\TEMP and down
  211.  
  212.  
  213. 2.4 LREN
  214. --------
  215. This command assigns a new long name to a file or directory. Do not use any wildcards 
  216. (?,*); rename only a single file or directory. You will not be able to rename a file 
  217. to a name containing unicode characters such as the Euro Symbol. Renaming to a short 
  218. name does not remove the long name; its case is stored in this place for example. 
  219.  
  220. Syntax: LREN [drive:][path\]filename newfilename [/?]
  221.  
  222. Example: C:\TEMP>LREN "An important file.txt" "Not so important any more.txt"
  223.  
  224.          C:\TEMP>
  225.  
  226.  
  227. 2.5 LCOPY
  228. ---------
  229. This command copies one or more files to any destination. You can use wildcards (?,*) 
  230. to select more than one file. If files already exist in the destination directory the 
  231. user is prompted if to proceed. This prompting can be turned off with the /Y switch. 
  232. If the targetfile is read-only, hidden or system the file is not copied by default. 
  233. To overwrite even those files, use the switch /R. The DOS 8.3 name is used for the 
  234. target file if possible. If however a file with that name already exists a new unique 
  235. 8.3 alias is created. When copying from CD a new 8.3 name is generated by default. 
  236. However by specifying the /K switch LCOPY will use the short name provided by the CD 
  237. file system. If the destination is omitted the current drive and directory are used. 
  238. The switch /S copies also all subdirectories with their contents. The /E switch 
  239. prevents that empty directories are copied. When using the /D switch together with /S 
  240. all matching files in all subdirectories are copied (collected) to the same 
  241. destination directory and no subdirectories are created. The switch /A copies also 
  242. hidden files. If /A and /S are combined even hidden directories are copied. With the 
  243. /C switch you can turn off the cache. This will slow down the whole thing a bit, but 
  244. consumes less memory (~128 KB). If you have a memory manager like EMM386 installed 
  245. LCOPY tries to use extended memory (EMS and XMS) for the cache. This improves 
  246. performance on huge directories but is slightly slower with short ones. If you prefer 
  247. not to use extended memory use the /V switch. You can abort the operation by pressing 
  248. any key. [The "any" key is the space bar ;-)] The /B switch turns off this feature. 
  249. The /I and /T switches are for CD-ROM only. /I forces LDIR to use ISO file system 
  250. rather than Joliet. /T must be followed by the number of a data track. The track 
  251. number identifies which session to use. When /T is absent the last session recorded 
  252. is used. Use LCHK to display valid track numbers. 
  253.  
  254. Note: When copying files from CD-ROM to hard drive, read-only attribute is NOT set by 
  255. default. 
  256.  
  257. Syntax: LCOPY [drive:][path\]sourcefile [drive:][destination] 
  258. [/?][/S [/D]][/E][/A][/C][/V][/R][/Y][/B][/I][/Tn]
  259.  
  260. Example: C:\TEMP>LCOPY "*.text" A:\BACKUP\
  261.          A Secret.text
  262.          An important.text
  263.          2 file(s) copied
  264.  
  265.          C:\TEMP>LCOPY "A Secret.text" "D:\WEB\Now A Public.text"
  266.          A Secret.text
  267.          1 file(s) copied
  268.  
  269.          C:\TEMP>LCOPY C:\WINDOWS\* "D:\WRECKED SYSTEMS" /A /S /B
  270.  
  271. The last line would copy the entire operating system to another directory. You are 
  272. not allowed to abort the operation.
  273.  
  274. C:>LCOPY . D:\ /S
  275.  
  276. The last line would copy the directory structure only (no files). With switches /S 
  277. LCOPY always mirrors the directory structure, even if no matching file is found.
  278.  
  279. C:\>LCOPY *.ZIP C:\ARCHIVES /S /D
  280.  
  281. The last line would copy all zip files on drive C to the directory \ARCHIVES. No 
  282. subdirectories are created.
  283.  
  284. 2.6 LMD
  285. -------
  286. This command creates a new subdirectory (folder).
  287.  
  288. Syntax: LMD [drive:][path\]newdir [/?]
  289.  
  290. Example: C:\>LMD "Backup Folder"
  291.          Ok.
  292.          C:\>LCD Backup*
  293.          C:\BACKUP~1>D:
  294.          D:\>LMD "C:Apr 1,1999"
  295.          Ok.
  296.  
  297. This creates a new Folder called "Apr 1,1999" in "Backup Folder" on drive C.
  298.  
  299. 2.7 LRD
  300. -------
  301. This command removes a subdirectory (folder).
  302.  
  303. Syntax: LRD [drive:][path\]dirname [/?]
  304.  
  305. Example: C:\>LRD "Backup Folder"
  306.          Ok.
  307.  
  308. 2.8 LCHK
  309. --------
  310. This command displays information about a disk. This information is taken from the 
  311. disk's boot sector. This command works on CD-ROMs as well. It displays detailed 
  312. information on how many tracks (sessions) are on the CD-ROM. Use the track numbers 
  313. displayed for the /T switch of LCOPY, LDIR and LCD.
  314.  
  315. Syntax: LCHK [drive:]
  316.  
  317. Example: C:\>LCHK D:
  318. Version 1.41
  319. Copyright (C) 1999 Ortwin Glueck
  320. This is free software under GPL. See the readme file for details.
  321.  
  322. DOS Version: FF-7.10
  323. Drive: 3
  324. Bytes per Sector: 512
  325. Sectors per Cluster: 8
  326. Reserved Sectors: 32
  327. Number of Clusters: 917916
  328. Number of FATs: 2
  329. Number of Root entries: 0
  330. Media Descriptor: f8
  331. Sectors per FAT: 7179
  332. Sectors: 7357707
  333. First Data Sector: 14390
  334. First Root Sector: 14390
  335. First Root Cluster: 2
  336. Root Sectors: 0
  337. Fat entries per Sector: 128
  338. Label:
  339. File System: FAT32
  340. FAT32 compatible disk access enabled
  341. Volume locking enabled
  342.  
  343. 3. Known bugs and features
  344. --------------------------
  345.  
  346. - LDIR "D:\My Files\" does not work as expected. Leave away the last backslash. Dos 
  347. seems to convert \" into a quotation mark (") at the very end.
  348. - The DOS command line can not exceed 127 characters! (use asterix to abbreviate 
  349. directories). Even batch file command lines will only pass 126 characters!
  350. - You can not use LCOPY to create a file whose name equals the drive label in the 
  351. drive's root directory. This is a DOS limitation. The LABEL command of DOS prior to 
  352. 6.22 can destroy long filenames. [MS KB Q118493]
  353. - Only Unicode characters from codepages 00h and 25h are translated. Unknown 
  354. characters are converted to underscore (_). May cause non-unique filenames!
  355. - LRD: You can remove the current working directory without notice.
  356. - If a disk's boot record reports a wrong FAT format, FAT is corrupted (lcopy, lmd, 
  357. lrd). This can especialy happen on (old) wrong formatted floppy disks. Check the 
  358. filesystem with the LCHK tool first. 1.44MB-Diskettes should always be FAT12.
  359. - FAT32: Only the first copy of the FAT is used for reading. Changes are ALWAYS 
  360. written to all copies (mirroring).
  361. - FAT32 hard drives can only be accessed if the DOS version supports FAT32. Otherwise 
  362. the drive is not assigned a drive letter. Use a Win98 or Win95B boot diskette.
  363. - CD-ROMs can only be accessed if a CD-ROM driver is loaded (MSCDEX). Otherwise the 
  364. drive is not assigned a drive letter.
  365. - I have made a short test with IDE-ATAPI Iomega ZIP drives. LFN Tools seem to work 
  366. fine on them. However one user reported problems when writing which I could not 
  367. reproduce.
  368. - Network drives are not supported.
  369. - When using the virtual memory cache (default) you need to load himem.sys and 
  370. EMM386.
  371.  
  372.  
  373. 4. Where can I report bugs and get an updated version?
  374. ------------------------------------------------------
  375. Any comment is to be sent to the e-mail address supplied on my homepage. I speak 
  376. German and English.
  377. Odi's LFN Tools are still under light development. So be sure to check for a newer 
  378. version every 6 months or so. Type LCHK to find out what version you have.
  379. Get the latest version from WWW: http://www.odi.ch/
  380.  
  381. 5. FAQ
  382. ------
  383. Q: Can LFN Tools access a network drive?
  384. A: No. LFN Tools need physical access to individual sectors of the drive. This is not 
  385. supported by DOS network drives.
  386.  
  387. Q: I have problems with my home burned CD-Rs. I cannot see long filenames.
  388. A: Learn how to use your CD recording software and read about CD-ROM standards. You 
  389. might have burned a darkgreenwithyellowspots-book CD.
  390.  
  391. Q: I would like to support your work with my money.
  392. A: Please read the "Donations" Section.
  393.  
  394. Q: I have programmed a DOS utility. Could you convert it to handle long names?
  395. A: Definitely not! Fix it yourself. You have the LFN source code.
  396.  
  397. Q: When trying LCOPY c:\*.* d:\ not all files are copied.
  398. A: Use * instead of *.* and RTFM.
  399.  
  400. Q: I need a 16-bit compiler in order to compile your source code.
  401. A: You must use Microsoft Visual C++ v1.51! Write to a newsgroup and ask for it. You 
  402. will certainly find a person who owns an old CD-ROM. You could use some Borland C++ 
  403. 5.0 too, but this requires sophisticated modifications of the code. The vmemory 
  404. library is by Microsoft and usually not included with compilers other than MS.
  405.  
  406. Q: Please place your program on my website and inform me about new releases.
  407. A: Please do that yourself! You are allowed to. Check back to my website every 3 
  408. months.
  409.  
  410. Q: I lost all my data after using your tools.
  411. A: Sorry for that. Backup important data regularly. I do not guarantee that the 
  412. software works always and everywhere. Please let me know what EXACTLY you did. See 
  413. section 4.
  414.  
  415. 6. Donations
  416. ------------
  417. You can support LFN Tools by donating a small amount of money. Please log on to 
  418. http://www.paypal.com/ and create an account. Send your donation to the following 
  419. Email Adress: odi@odi.ch
  420.  
  421.  
  422. 7. License
  423. ----------
  424. This is free software under the GNU General Public License. No warranty. Source code 
  425. (MS-C++) available on http://www.odi.ch/. If you can not compile the code with your 
  426. favourite compiler this is YOUR problem. I can not help you compile the code.
  427. See the license.txt file included in the ZIP archive.
  428.  
  429. 8. Acknowledgements
  430. -------------------
  431. I would like to say thank you to:
  432.  
  433. Marcin Frankowski (NZ) for Latin-2 support
  434. Geert Keteleer for valuable help and the cars :-)
  435. Kurt Salentin for the debugging
  436. Milan Stanik
  437. Wolf Bartels
  438. Silvio Vernillo
  439. Alfred Schumann
  440. Ralph E. Griffin 
  441. Herbert Schmidt, Martin Kunkel for the key hints on the bootable CD problem
  442. Martin Kunkel for his digging in my code
  443. Frank Littmann, Mario Latzig for hints on filename problem with Joliet
  444. (Odi can't code...)
  445. Bill Hall for some good hints
  446. Isy for two bug reports
  447. 64.245.58.28 for cool sound (R.I.P.)
  448. H. Ellenberger for the bug report in 1.42
  449. Benjamin Wells for his note on LCOPY *.TXT C:\FUN /S
  450. Mark Marinac for his hints on ZIP drives and compression
  451. Michael Marquart for the hint on DOS 6 and extensive testing
  452. Leanne & Walt Smith for the IBM PC-DOS testing
  453. Gordon Chaffee for Unicode support (Linux kernel)
  454. The Linux people who helped me out with the ISO structs
  455.